from lxml import etree
import requests
headers = {
    'User-Agent': 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/84.0.4147.105 Safari/537.36'
}

page_text = requests.get(url='https://www.lagou.com/shanghai-zhaopin/Python/?labelWords=label',headers=headers).text
tree = etree.HTML(page_text)
li_list = tree.xpath('//*[@id="s_position_list"]/ul/li')
for li in li_list:
    xxx = li.xpath("./div[1]/div[1]/div[1]/a/h3/text()")[0]
    urls = li.xpath('./div[1]/div[1]/div[1]/a/@href')[0]
    print(xxx,urls)